home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 2: Applications / Linux Cubed Series 2 - Applications.iso / database / postgres / appgen-0.2-a / appgen-0 / AppGEN / src / lib / itoa.c < prev    next >
Encoding:
C/C++ Source or Header  |  1996-07-10  |  302 b   |  20 lines

  1. #include <stdlib.h>
  2. #include <stdio.h>
  3.  
  4. char *ag_itoa(char *buf, int value)
  5. {
  6.     int a;
  7.     for (a=0; a<64; a++) buf[a]=0;
  8.     sprintf(buf,"%d",value);
  9.     return(buf);    
  10.  
  11. }
  12.  
  13. char *ag_sprintf(char *buf, char *format, int value)
  14. {
  15.     int a;
  16.     for (a=0; a<64; a++) buf[a]=0;
  17.     sprintf(buf,format,value);
  18.     return(buf);
  19. }
  20.